export function toArray(val: any) {
  return [].slice.call(val);
}

export function isText(node: Node | Text) {
  return node && node.nodeType === window.Node.TEXT_NODE;
}

export function isElem(node: Node | Text) {
  return node && node.nodeType === window.Node.ELEMENT_NODE;
}
